package com.sfac.entity.account;

import com.sfac.entity.common.AbstractEntity;

import java.util.List;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;



@Entity
@Table(name = "account_menu")
public class Menu extends AbstractEntity {

	private static final long serialVersionUID = 1L;
	private String title;
	private String path;
	private String icon;
	private int parentId;
	// 菜单显示优先级，格式：parentId-index
	private int priority;
	@Transient
	private List<Menu> subItems;

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getPath() {
		return path;
	}

	public void setPath(String path) {
		this.path = path;
	}

	public String getIcon() {
		return icon;
	}

	public void setIcon(String icon) {
		this.icon = icon;
	}

	public int getParentId() {
		return parentId;
	}

	public void setParentId(int parentId) {
		this.parentId = parentId;
	}

	public List<Menu> getSubItems() {
		return subItems;
	}

	public void setSubItems(List<Menu> subItems) {
		this.subItems = subItems;
	}

	public int getPriority() {
		return priority;
	}

	public void setPriority(int priority) {
		this.priority = priority;
	}

}
